<template>
	<view class="item_pro" @click="itemClick">
		<view class="item_img">
			<image :src="item.pic" class="item_img"></image>
		</view>
		
		<view class="linetxt">
			<view class="linetxttitle"><text class="linetxttitlel">{{item.title}}</text></view>
			<!-- <view class="homeiconbox"><image src="/static/imgs/dianzan.png" class="homeicon"></image></view> -->
			<view class="homeiconbox" @click.stop="follow"><image :src="item.isFollow==1?'/static/imgs/shoucang.png':'/static/imgs/noshoucang.png'" class="homeicon"></image></view>
		</view>
		<view class="txtinfo">
			<text class="infotxt">{{item.recommend_intro}}</text>
		</view>
		<view class="labelsbox">
			<view class="labelaa"> <text class="labellabel" v-for="(tag,inx) in item.tags" :key="inx">{{tag}}</text></view> 
		</view>
		<view class="txtinfo">
			<image src="/static/imgs/icon-location.png" class="locationicon"></image><text class="infotxta">{{item.address}}</text>
		</view>
	</view>
</template>

<script>
	export default {
		props:{
			item:{
				type:Object,
				default:{}
			}
		},
		methods:{ 
			itemClick(){
				this.$emit("goInfo")
			},
			follow(){
				this.$emit("follow")
			}
		}
	}
</script>

<style scoped>
	.infotxta{
		color:#D8D8D8;
		font-size: 20upx;
	}
	.locationicon{
		width: 32upx;
		height: 32upx;
		margin-right: 10upx;
	}
.labelsbox{
		width: 650upx;
		height: auto;
		flex-direction: row;
		padding-left: 40upx;
	}
	.labellabel{
		color: #CBCBCB;
		font-size: 24upx;
	}
	.labelaa{
		border-style:bold ;
		border-color: #CBCBCB;
		border-width: 2upx;
		border-radius: 4upx;
		
		margin-right: 20upx;
		padding: 4upx 8upx;
	}
	.txtinfo{
		width: 690upx;
		height: 40upx;
		padding-left:40upx ;
		margin-top: 20upx;
		flex-direction: row;
	}
	.infotxt{
		color: #717171;
		font-size: 26upx;
	}
	.item_pro{
		padding-top: 30upx;
		width: 100%;
		height: 700upx;
	}
	.item_img{
		width: 690upx;
		height: 390upx;
		margin: 0 auto;
		border-radius: 10upx;
		
	}
	.linetxt{
		width: 100%;
		height: 50upx;
		padding: 0upx 30upx;
		box-sizing: border-box;
		display:flex;
		flex-direction: row;
		margin-top: 30upx;
	}
	.linetxttitlel{
		
		font-size: 40upx;
		color: #333;
		font-weight: bold;
		margin-left: 10upx;
	}
	.linetxttitle{
		flex: 8;
	}
	.homeiconbox{
		flex: 1;
		
	}
	.homeicon{
		width: 40upx;
		height: 40upx;
	}
</style>
